package com.crm.service.saling;

import com.crm.pojo.PlaningBack;
import com.crm.vo.PlaningBackClientContractUserInfoVO;

import java.math.BigDecimal;
import java.util.List;

/**
 * Created by dr5hx on 2018/8/26
 */
public interface PlaningBackService {

    /**
     * 统计对应合同订单的所有回款金额
     *
     * @param contractId
     * @return
     */
    public BigDecimal countPlaningBackMoneyByContractId(Long contractId);


    /**
     * 保存计划回款的数据
     *
     * @param list
     * @return
     */
    public Boolean savePlaningBackDataList(List<PlaningBack> list);

    /**
     * 保存回款计划数据
     *
     * @param planingBack
     * @return
     */
    public Boolean savePlaningBackData(PlaningBack planingBack);

    /**
     * 查询合同/订单对应的回款计划单
     *
     * @param ContractId
     * @return
     */
    public List<PlaningBack> getPlaningBackByContractId(Long ContractId);


    /**
     * 查询一条未删除的计划汇款记录
     *
     * @param planingBack
     * @return
     */
    public PlaningBack getPlaningBackRecord(Long planingBack);

    /**
     * 获取回款计划数量
     *
     * @return
     */
    public Long getPlaningBackCount();

    /**
     * 分页显示回款计划列表
     *
     * @param currpage
     * @param rows
     * @return
     */
    public List<PlaningBackClientContractUserInfoVO> getPlaningBackClientContractUserInfoVOList(int currpage, int rows);


}
